#pragma once
#define _USE_MATH_DEFINES
#include <iostream>
#include <fstream>
#include <vector>
#include <cmath>
#include <math.h>
#include <Eigen/Dense>

using namespace std;
using namespace Eigen;

#define NODE_NUM_AC 18
#define BRANCH_NUM_AC 36
#define NODE_NUM_DC 4
#define BRANCH_NUM_DC 9
#define PI acos(-1.0)

class Capacitor
{
public:
	double cap_g;
	double cap_v;
	double cap_ib;
	double cap_jh;
};

class Inductor
{
public:
	double ind_g;
	double ind_v;
	double ind_ib;
	double ind_jh;
};

class Switch
{
public:
	double g;
	double gon;
	double goff;
};

class VSC
{
public:
	double g_vsc;
	double gon_vsc;
	double goff_vsc;
	double g_snubber;

};

extern "C" int pvmodel_pre(double* _G_PVunit, double* _INJ_ABC, double* _V_ABC, double* _DELT, 
    double* _PVarray_pars, double* _Boost_pars, double* _CPB_pars, double* _VSC_pars, double* _LC_pars, double* _PVunit_Bre_pars, double* _Trans_pars, double* _DATA_OUT);
extern "C" int pvmodel(double* _G_PVunit, double* _INJ_ABC, double* _V_ABC, 
    int* _Dblk1, int* _SW_AC, int* _SW_DC, double* _Vchar, double* _DATA_OUT);